<?php
/**
 * @property int $article_id
 * @property int $tag_id
 */
class ArticleToTag extends ActiveRecord
{
	public static function model($className = __CLASS__)
	{
		return parent::model($className);
	}

	public function tableName()
	{
		return 'article_to_tag';
	}

	public function relations()
	{
		return array(
			'tag' => array(self::BELONGS_TO, 'Tag', 'tag_id'),
			'article' => array(self::BELONGS_TO, 'Article', 'article_id'),
		);
	}
}